@import "common/var";

@include b(table) {
  background-color: $--background;

  @include e(pager) {
    padding: 12px 0 !important;
  }

  @include e(skeleton) {
    padding: 12px;
    text-align: center;
    color: $--color-info
  }

  @include e(complete) {
    padding: 12px;
    text-align: center;
    color: $--color-info
  }

  @include e(placeholder) {
    position: absolute;
    left: 0;
    top: 0;
    right: 0;
    z-index: -1;
  }

  @include e(ghost) {
    background-color: $--color-warning-lighter !important;
  }
  @include e(fallback) {
    background-color: $--color-success-lighter !important;
    td {
      background-color: $--color-success-lighter !important;
    }
  }

  @include when(row-sortable) {
    .el-table__row {
      cursor: move;
    }
  }

  @include when(fit) {
    width: 100%;
    height: 100%;
  }

  @include m(header-bg) {
    .el-table__header-wrapper {
      th {
        background: $--color-table-header;
      }
    }
  }
}

@include b(table-toolbar) {
  height: 40px;
  line-height: 40px;
  position: relative;
  margin-bottom: 12px;

  @include e(title) {
    font-size: $--font-size-medium;
    padding: 0;
  }
  @include e(actions) {
    position: absolute;
    right: 0;
    top: 0;
    line-height: 1;
  }

  @include m(medium) {
    height: 36px;
    line-height: 36px;
  }
  @include m(small) {
    height: 32px;
    line-height: 32px;
  }
  @include m(mini) {
    height: 28px;
    line-height: 28px;
  }

}

@include b(table-column-filter) {
  position: relative;
  left: -5px;

  @include e(trigger) {
    cursor: pointer;
    outline: none;
    &:hover {
      opacity: 0.8;
    }
  }

  @include e(popper) {
    min-width: 80px !important;
    .el-checkbox {
      display: block;
      margin-right: 0;
    }
  }
}

